﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using SqlSugar;

namespace MyBlog.Model
{
    public class BlogNews:BaseId
    {
        //标题
        [SugarColumn(ColumnDataType ="nvarchar(30)")]
        public string Title { get; set; }
        //文本内容
        [SugarColumn(ColumnDataType = "text")]
        public string Content { get; set; }
        //创建时间
        public DateTime Time {get; set; }
        //浏览量
        public int BrowseCount { get; set; }
        //点赞量
        public int LikeCount { get; set; }

        //类型ID
        public int TypeId { get; set; }
        //作者ID
        public int WriterId { get; set; }

        //类型
        [SugarColumn(IsIgnore =true)]
        public TypeInfo TypeInfo { get; set; }
        //作者
        [SugarColumn(IsIgnore = true)]
        public WriterInfo WriterInfo { get; set; }  
    }
}
